1)){let a="location_capture"===t?document.createElement("select"):document.createElement("input");if("SELECT"===a.tagName){a.required=!0,a.name="favorite_location_id";let n=new Option("Select your favorite location...","",!1,!0);n.disabled=!0,n.hidden=!0,a.add(n),e.design.locations.forEach((function(e){a.add(new Option(e.name,e.id))}))}"utmData"===o?(a.style.cssText="display:none",a.value=n[t]):(a.style.cssText="border: 1px inset rgba(0,0,0,0.15);width:100%;line-height:1.2;font-size:"+ae.body_text_size+"px;padding:12px;margin-bottom:8px;box-sizing:border-box;border-radius:"+pe+";background-color:"+ae.input_background_color,"ql"===ae.font.split("-")[0]?a.classList.add(ae.font):a.style.font=ae.font);let d=t.substring(0,t.indexOf("_capture")),c=(d[0].toUpperCase()+d.substring(0,t.length).substring(1,d.length)).replace("_"," ");switch(a.ariaLabel=c,a.required=!0,"success"!==o&&"Email"!==c&&"utmData"!==o&&a.classList.add("comodal-mobile-hide"),c){case"Email":a.type="email",a.title="Please enter email in format xxxx@xxx.xxx","offer_campaign_v2"!==re?.modal_template&&"non_offer"!==re?.modal_template||a.addEventListener("focus",(()=>{h.style.display="inline",te.style.display="block"}));break;case"Phone number":i=!0,a.type="tel",a.addEventListener("keyup",(function(){var e=/^((1)?[2-9]([0-9]){9}|(61)?(0)?[1-9]([0-9]){8}|(64)?(([0-9]){8,9}|02[0-9]{7,9}))$/;a.value.replace(/\D/g,"").match(e)?a.setCustomValidity(""):a.setCustomValidity("Please enter a valid phone number.")}));break;default:a.type="text"}if("name"===d){var s=a.cloneNode();a.id="first_name","ql"===ae.font.split("-")[0]?a.classList.add(ae.font):a.style.font=ae.font,a.style.cssText="border: 1px inset rgba(0,0,0,0.15);width:49%;line-height:1.2;font-size:"+ae.body_text_size+"px;padding:12px;margin-bottom:8px;box-sizing:border-box;border-radius:"+pe+";background-color:"+ae.input_background_color,a.pattern="^[A-Za-z\\-' ]+$",a.title="Symbols and numbers not allowed.",a.placeholder="First Name",s.id="last_name","ql"===ae.font.split("-")[0]?s.classList.add(ae.font):s.style.font=ae.font,s.style.cssText="border: 1px inset rgba(0,0,0,0.15);float:right;width:49%;line-height:1.2;font-size:"+ae.body_text_size+"px;padding:12px;margin-bottom:8px;box-sizing:border-box;border-radius:"+pe+";background-color:"+ae.input_background_color,s.pattern="^[A-Za-z\\-' ]+$",s.title="Symbols and numbers not allowed.",s.placeholder="Last Name",r.prepend(s),r.prepend(a)}else if("birthday"===d){var l=a.cloneNode();a.id="birthday_month","ql"===ae.font.split("-")[0]?a.classList.add(ae.font):a.style.font=ae.font,a.style.cssText="border: 1px inset rgba(0,0,0,0.15);width:49%;line-height:1.2;font-size:"+ae.body_text_size+"px;padding:12px;margin-bottom:8px;box-sizing:border-box;border-radius:"+pe+";background-color:"+ae.input_background_color,a.placeholder="Birth Month (MM)",l.id="birthday_day","ql"===ae.font.split("-")[0]?l.classList.add(ae.font):l.style.font=ae.font,l.style.cssText="border: 1px inset rgba(0,0,0,0.15);width:49%;float:right;line-height:1.2;font-size:"+ae.body_text_size+"px;padding:12px;margin-bottom:8px;box-sizing:border-box;border-radius:"+pe+";background-color:"+ae.input_background_color,l.title="Symbols not allowed.",l.placeholder="Birth Day (DD)",r.appendChild(a),r.appendChild(l)}else a.id=d,a.placeholder="Zip code"===c?c.replace("Zip code","Zip Code"):"Phone number"===c?c.replace("Phone number","Phone Number"):"Email"===c?"offer_campaign_v2"===re?.modal_template?"Enter email to claim":"Enter email to sign up":c,r.appendChild(a)}if("signup"===o){(h=m("div")).style.fontSize="12px",h.style.opacity="0.8";var d=t(ae.background_color);h.style.color=d,h.style.textAlign="left",h.style.display="offer_campaign_v2"===re?.modal_template||"non_offer"===re?.modal_template?"none":"inline-block",h.style.lineHeight="1.2";var c,p,g="non_offer"===W.design.signUpModal?.modal_template?"\n \n Must subscribe via email, opt into inKind\u2019s text messaging, and download + create an account on the inKind app to participate.\n \n \n
\n ":"general"!==W.design.signUpModal?.modal_template?`\n \n Limited to new inKind users only. Must subscribe via email,\n opt into inKind's text messaging, and download +\n create an account on the inKind app to redeem.
Offer terms apply\n \n
\n
\n
\n `:"",f=!1===W.design.signUpModal?.cobranding_legal&&W.design.signUpModal?.cobranding_rules_url?.length&&W.design.signUpModal?.cobranding_rules_caption?.length>0?`\n \n `:"",_=`By continuing, I agree to receive ${i?"email and text":"marketing"} messages from ${a(W.behavior.project_name,W.behavior.brand_name)} ${!0===W.design?.signUpModal?.cobranding_legal?"in partnership with inKind":""} ${i?"including marketing messages, at the phone number provided. Message frequency varies. Reply HELP for help or STOP to cancel. Message & data rates may apply.
By continuing, I also":"and"}`;!0===W.design?.signUpModal?.cobranding_legal?(c=" consent to the inKind",p=`
Terms of Service ,\n
\n Privacy Policy , and\n
\n Notice of Financial Incentive .\n
`):(c=" consent to the ",p=W.design.signUpModal?.cobranding_terms_url?.length>0&&W.design.signUpModal?.cobranding_privacy_policy_url?.length>0?` Terms of Service \n and\n \n Privacy Policy\n .`:` 0?W.design?.signUpModal?.cobranding_privacy_policy_url:W.design?.signUpModal?.cobranding_terms_url}\n >Terms of Service and Privacy Policy .`);var b=_+c+p;h.innerHTML=g+f+b,h.classList.add("comodal-mobile-hide"),r.appendChild(h)}if(i&&"success"===o&&!W.design.successModal.link_to_offer){var h=m("div");d=t(ae.background_color);h.style.fontSize="12px",h.style.display="offer_campaign_v2"===re?.modal_template||"non_offer"===re?.modal_template?"none":"inline",h.style.padding="8px",h.style.color=t(ae.background_color),h.style.textAlign="center",h.style.lineHeight="1.2";var y=`By continuing, I agree to receive email and text messages from ${W.behavior.project_name!==W.behavior.brand_name?`${W.behavior.project_name} and ${W.behavior.brand_name} `:`${W.behavior.project_name} `}, in partnership with inKind, including marketing messages, at the phone number provided. Message frequency varies. Reply HELP for help or STOP to cancel. Message & data rates may apply.
`;h.innerHTML=y,r.appendChild(h)}"signup"===o?u(te,N,("offer_campaign_v2"===re?.modal_template||"non_offer"===re?.modal_template?"display:none;":"display:inline-block;")+"border:0px;width:100%;margin-top:15px;font-size:16px;padding:12px;box-sizing:border-box;font-size:1rem;font-weight:500;cursor:pointer;background-color:"+ae.button_color+";color:"+ae.button_text_color+";border-radius:"+pe,re.button_label,ae.font):""!==se.success_button_label.trim()&&u(ie,ne,"border:0px;display:block;text-align:center;width:100%;font-size:16px;padding:12px;margin-top:15px;box-sizing:border-box;font-size:1rem;font-weight:500;cursor:pointer;background-color:"+ae.button_color+";color:"+ae.button_text_color+";border-radius:"+pe,se.success_button_label,ae.font)}X>=e.behavior.impressions_limit&&"signup_to_fab"===e.design.floatingAccessButton.fab_behaviour&&(e.design.floatingAccessButton.fab_behaviour="signup_modal");const p="co_modal_none"!==e.design.coModals.co_modal_configuration&&null===o.readCookie(F+n+"_comodal")&&!!r(e.design.coModals.co_modal_start_date,e.design.coModals.co_modal_end_date);if("no_display"!==e.design.signUpModal.signup_modal_display_position&&(p||null===o.readCookie(F+n))){var g=document.getElementsByTagName("body")[0],b=m("iframe");b.id="frame",b.title="A special welcome gift","no_display"!==e.design.signUpModal.signup_modal_display_position&&"desktop_fab_none"===e.design.floatingAccessButton.desktop_display_location&&"mobile_fab_mobile_none"===e.design.floatingAccessButton.mobile_display_location?b.className="":"signup_to_fab"===e.design.floatingAccessButton.fab_behaviour?b.className="iframe-entered":"tiers"!==e.design.floatingAccessButton.fab_behaviour&&(b.className="iframe-unentered");var h=m("div"),x=m("div"),w=m("div"),k=m("div"),C=m("div");C.classList.add("comodal-image-container");var L=m("div"),E=m("div"),z=m("div"),B=m("img");B.src="https://res-5.cloudinary.com/"+P+"/image/upload/c_fit,w_320/"+e?.design?.colorAndStyle?.brand_image_url,B.alt=`${e?.behavior?.brand_name} logo`,B.classList.add("comodal-mobile-hide");var A=m("div"),T=m("div"),S=m("div"),q=m("button");q.classList.add("close-button"),q.setAttribute("aria-label","close button");var D=m("img"),I=m("div"),U=m("div"),j=m("div"),N=m("form"),R=m("div"),Z=(m("div"),m("div"));Z.id="success-header";var K=m("div");K.id="success-message",T.id="header-message",j.id="body-message",j.className="comodal-mobile-hide";var G=m("div"),J=m("div");J.id="iframe-flex",J.role="dialog",J.title="inKind Offer Popup Modal",J.ariaModal="true",J.ariaDescribedBy="Popup modal with inKind offer",J.ariaLabelledBy="inKind Popup Modal",G.id="success-sub";var V=m("div"),Y=m("div"),ee=m("button");ee.classList.add("close-button"),ee.setAttribute("aria-label","success close button");var ne=m("form");ne.id="successForm";var te=m("button"),oe=m("button");oe.className="show-fab-button",oe.setAttribute("aria-label","floating action button"),te.id="signup-button-label",te.classList.add("comodal-mobile-hide"),te.setAttribute("aria-label",`${e?.design?.signUpModal?.button_label}`),W=e;var ie,ae=e.design.colorAndStyle,re=e.design.signUpModal,se=e.design.successModal,le=e.design.floatingAccessButton;if(Q(le),"offer_campaign"===W.design.signUpModal.modal_template||"offer_fixed"===W.design.signUpModal.modal_template||"offer_campaign_v2"===W.design.signUpModal.modal_template)(ie=m("a")).id="success-button-label";else(ie=m("button")).id="success-button-label";ie.setAttribute("aria-label",`${e?.design?.successModal?.success_button_label}`);var de=Math.floor(ae.border_radius)+"px",ce=ae.border_radius<=0?0:Math.floor(ae.border_radius+1)+"px",pe=Math.floor(ae.border_radius/2)+"px";h.id="inkindmodal",D.src=ae.header_image_url?.replace(".png",".jpg"),D.alt=W.design.signUpModal.image_alt_text,d(e.design.signUpModal.inputs,"signup"),d(e.design.successModal.inputs,"success"),d(c(e),"utmData"),u(h,g,"no_display"!==e.design.signUpModal.signup_modal_display_position&&"desktop_fab_none"===e.design.floatingAccessButton.desktop_display_location&&"mobile_fab_mobile_none"===e.design.floatingAccessButton.mobile_display_location?"background-color:rgb(8,8,8,0.75);z-index:2147483640;pointer-events:none;height:100%;width:100%;opacity:0%;align-items:center;justify-content:center;border:0;position:fixed;top:0px;-webkit-overflow-scrolling:touch;overflow-y:auto;":"tiers"!==e.design.floatingAccessButton.fab_behaviour?"z-index:2147483640;pointer-events:none;height:70px;width:70px;opacity:0%;align-items:center;justify-content:center;border:0;position:fixed;top:0px;-webkit-overflow-scrolling:touch;overflow-y:auto;":"background-color:rgb(8,8,8,0.75);z-index:2147483640;pointer-events:none;height:100%;width:100%;opacity:0%;align-items:center;justify-content:center;border:0;position:fixed;top:0px;-webkit-overflow-scrolling:touch;overflow-y:auto;"),u(b,h,"no_display"!==e.design.signUpModal.signup_modal_display_position&&"desktop_fab_none"===e.design.floatingAccessButton.desktop_display_location&&"mobile_fab_mobile_none"===e.design.floatingAccessButton.mobile_display_location?"background-color:transparent;width:100%;height:100vh;border:0px;position:fixed;left:0px;right:0px;max-width:none;":""),setTimeout((()=>{let a=m("title");a.textContent=`an opportunity to claim a special welcome gift for when you visit ${e?.behavior?.brand_name} and pay using the inKind app`,document.getElementById("frame").contentDocument.head.appendChild(a);var r=document.getElementById("frame").contentWindow.document,s=document.getElementById("frame").contentWindow.document.body;s?.focus(),"desktop_fab_none"!==e.design.floatingAccessButton.desktop_display_location&&"mobile_fab_mobile_none"!==e.design.floatingAccessButton.mobile_display_location&&(s.style.padding="0px",s.classList.add("signup_to_fab"===e.design.floatingAccessButton.fab_behaviour?"modal-body":"fab-body"));var d=document.getElementById("frame").contentWindow.document.head,c=document.createElement("style");if(ae.google_font_url){var g=r.createElement("link");g.setAttribute("href",ae.google_font_url),g.rel="stylesheet",g.type="text/css",d.appendChild(g)}var P=ae?.google_font_url?new URLSearchParams(ae.google_font_url?.split("?")[1]).get("family")?.split(":")[0]:null,H=ae?.google_font_url?P?".ql-font-"+P.replace(/\s/g,"").toLowerCase():"default-font":null,X=null===P?"":H+" { font-family: "+P+"; }"
;c.innerHTML="body ::placeholder { color: "+ae.placeholder_text_color+"; } input { color: "+ae.active_text_color+"; }"+X+`body::-webkit-scrollbar {\n display: none;\n }\n select:invalid {\n color: ${ae.placeholder_text_color}\n }\n select {\n -moz-appearance:none;\n -webkit-appearance:none;\n appearance:none;\n background-image: url('${O}round-keyboard_arrow_down-24px.svg');\n background-repeat: no-repeat;\n background-position-x: 96%;\n background-position-y: 50%;\n background-size: 10px auto;\n }\n .fab-body {\n min-height: 80px;\n background-color: ${ae.background_color};\n display: flex;\n justify-content: center;\n align-items: center;\n flex-direction: column;\n }\n .modal-body {\n background-color: rgba(8,8,8,0.75);\n }\n @media (hover: hover) {\n .fab-body:hover {\n background-color: ${ae.button_color}\n }\n }\n .show-fab-button {\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n gap: 2px;\n border-radius: ${"tiers"!==e.design.floatingAccessButton.fab_behaviour?"18px":"50%"};\n width: 76px;\n height: 76px;\n font-size: 12px;\n line-height: 12px;\n text-align: center;\n cursor: pointer;\n background-color: ${ae.button_color};\n color: ${ae.button_text_color};\n font-weight: bold;\n padding: 0;\n border: 0;\n appearance: none;\n -webkit-appearance: none;\n div {\n display: inline;\n }\n }\n .fab-offer-amount {\n font-size: 24px;\n line-height: 28px;\n }\n @media (hover: hover) {\n\n .show-fab-button:hover {\n background-color: ${ae.button_text_color} !important;\n color: ${ae.button_color} !important;\n transition: transform 0.3s;\n }\n }\n .slide-to-center {\n transition: left .5s linear;\n }\n\n p {\n margin-top: 0px;\n margin-bottom: 0px;\n }\n .ql-size-12px {\n font-size: 12px;\n }\n .ql-size-14px {\n font-size: 14px;\n }\n .ql-size-16px {\n font-size: 16px;\n }\n .ql-size-20px {\n font-size: 20px;\n }\n .ql-size-24px {\n font-size: 24px;\n }\n .ql-size-28px {\n font-size: 28px;\n }\n .ql-size-32px {\n font-size: 32px;\n }\n .ql-size-36px {\n font-size: 36px;\n }\n .ql-size-48px {\n font-size: 48px;\n }\n .ql-size-60px {\n font-size: 60px;\n }\n .ql-size-72px {\n font-size: 72px;\n }\n .ql-align-right {\n text-align: right;\n }\n .ql-align-center {\n text-align: center;\n }\n .ql-align-left {\n text-align: left;\n }\n .ql-align-justify {\n text-align: justify;\n }\n .ql-font-americantypewriter {\n font-family: "American Typewriter", serif;\n }\n .ql-font-andal\xe9mono {\n font-family: "Andale Mono", monospace;\n }\n .ql-font-arial {\n font-family: "Arial", sans-serif;\n }\n .ql-font-arialblack {\n font-family: "Arial Black", sans-serif;\n }\n .ql-font-courier {\n font-family: "Courier", monospace;\n }\n .ql-font-didot {\n font-family: "Didot", serif;\n }\n .ql-font-georgia {\n font-family: "Georgia", serif;\n }\n .ql-font-lucidaconsole {\n font-family: "Lucida Console", monospace;\n }\n .ql-font-luminari {\n font-family: "Luminari", sans-serif;\n }\n .ql-font-monaco {\n font-family: "Monaco", monospace;\n }\n .ql-font-tahoma {\n font-family: "Tahoma", sans-serif;\n }\n .ql-font-timesnewroman {\n font-family: "Times New Roman", serif;\n }\n .ql-font-trebuchet {\n font-family: "Trebuchet", sans-serif;\n }\n .ql-font-verdana {\n font-family: "Verdana", sans-serif;\n } body {\n min-height: calc(100vh - 16px);\n display: flex;\n align-items: ${"signup_center"===re.signup_modal_display_position||p&&null===o.readCookie(F+n)?"center":"flex-end"};\n justify-content: ${p&&null===o.readCookie(F+n)?"center":"signup_lower_left"===re.signup_modal_display_position?"start":"signup_lower_right"===re.signup_modal_display_position?"end":"center"};\n } .close-button {\n height: 35px;\n width: 35px;\n } #iframe-flex {\n display: flex;\n flex-direction: row;\n align-items: start;\n justify-content: center;\n max-width: calc(100% - 10px);\n outline: none;\n border-radius: ${ce} ${ce} ${de} ${de};\n } #iframe-flex > * + * {\n margin-left: 32px;\n } @media only screen and (max-width: 860px) {\n #iframe-flex {\n flex-direction: column;\n } #iframe-flex > * + * {\n margin-left: 0px;\n margin-top: 32px;\n }\n .close-button {\n height:20px;\n width:20px;\n }\n ${p?"\n .comodal-mobile-hide {\n max-height: 0px;\n padding-top: 0px!important;\n padding-bottom: 0px!important;\n margin-bottom: 0px!important;\n margin-top: 0px!important;\n border: 0px!important;\n overflow: hidden;\n transition: all .25s ease-in;\n }\n .comodal-image-container {\n max-height: 175px;\n overflow: hidden;\n transition: all .25s ease-in;\n }\n .comodal-mobile-show {\n transition: all .25s ease-in;\n max-height: 500px;\n }\n ":""}\n\n } @media only screen and (max-width: 448px) {\n body {\n margin: 0px;\n align-items: center;\n justify-content: center;\n max-width: 100%;\n }\n } #success-message, #body-message { color: ${t(ae.background_color)} } #header-message {color: ${t(ae.tout_background_color)}`,s.append(c);const Q=!!navigator.userAgent.match(/safari/i)&&!!navigator.vendor.match(/apple/i)&&!!navigator.maxTouchPoints;u(oe,s,"no_display"!==e.design.signUpModal.signup_modal_display_position&&"desktop_fab_none"===e.design.floatingAccessButton.desktop_display_location&&"mobile_fab_mobile_none"===e.design.floatingAccessButton.mobile_display_location||"signup_to_fab"===e.design.floatingAccessButton.fab_behaviour?"display:none;":null,oe.innerHTML=`GET ${le.offer_amount}
ON US`,ae.font),u(J,s),null===o.readCookie(F+n)&&u(x,J,"no_display"!==e.design.signUpModal.signup_modal_display_position&&"desktop_fab_none"===e.design.floatingAccessButton.desktop_display_location&&"mobile_fab_mobile_none"===e.design.floatingAccessButton.mobile_display_location?`width:400px; box-shadow: 0 0px 2px rgba(255,255,255,0.85), 0 5px 15px rgba(0,0,0,.65); border-radius: ${ce} ${ce} ${de} ${de}; position: relative; left: 0px;top:0px;max-width:100%;${Q?"margin-bottom:100px;":""}font-family:`:"signup_modal"===e.design.floatingAccessButton.fab_behaviour?"display:none;":"signup_to_fab"===e.design.floatingAccessButton.fab_behaviour?`display: block; width: 400px; max-width: 100%; box-shadow: 0 0px 2px rgba(255,255,255,0.85), 0 5px 15px rgba(0,0,0,.65); border-top-left-radius: ${e.design.colorAndStyle.border_radius+1}px; border-top-right-radius: ${e.design.colorAndStyle.border_radius+1}px; border-bottom-left-radius: ${e.design.colorAndStyle.border_radius}px;border-bottom-right-radius: ${e.design.colorAndStyle.border_radius}px;`:`width:400px; box-shadow: 0 0px 2px rgba(255,255,255,0.85), 0 5px 15px rgba(0,0,0,.65); border-radius: ${ce} ${ce} ${de} ${de}; position: relative; left: 0px;top:0px;max-width:100%;${Q?"margin-bottom:100px;":""}font-family:`,null,ae.font),u(w,x,"z-index:2147483641; 0 0px 2px rgba(255,255,255,0.85), 0 5px 15px rgba(0,0,0,.65); border-radius:"+de+";background-color:"+ae.background_color+";border-top-right-radius:"+ce+";border-top-left-radius:"+ce+";"),u(k,w,"border-bottom-left-radius:"+de+";border-bottom-right-radius:"+de+";"),u(C,k,"position:relative;"),u(L,C,"position:absolute;height:50%;width:100%;z-index:200;"),u(E,C,"position:absolute;display:flex;align-items:center;justify-content:center;flex-direction:column;height:100%;width:100%;display:flex;flex-direction:column;justify-content:space-evenly;overflow:hidden;"),u(z,E,`margin-left:8px;margin-right:8px;margin-bottom:${"offer_campaign_v2"===!re?.modal_template&&!0===re?.cobranding_legal?"24px":!0===re?.cobranding_legal&&"offer_campaign_v2"===re?.modal_template?"0px":""};margin-top:${!0===re?.cobranding_legal&&"offer_campaign_v2"===re?.modal_template?"24px":"0px"};display:flex;flex-direction:column;align-items:center;justify-content:space-evenly;max-height:280px;gap:8px;`),"offer_campaign"===re?.modal_template&&ae?.brand_image_url&&u(B,z,"width:160px;height:auto;"),("offer_campaign_v2"===re?.modal_template||"non_offer"===re?.modal_template)&&ae?.brand_image_url&&u(B,z,"width:160px;height:auto;position:absolute;top:8px;"),re?.image_overlay_text&&u(T,z,"width:332px;",re.image_overlay_text),"offer_campaign"===re?.modal_template&&!0==!!re?.cobranding_legal&&u(A,C,"font-size:20px;line-height:28px;color:white;",`REDEEMABLE WITH
`),("offer_campaign_v2"===re?.modal_template||"non_offer"===re?.modal_template)&&!0==!!re?.cobranding_legal&&u(A,C,"font-size:20px;line-height:28px;color:white;",`using the
rewards app
`),"non_offer"===re?.modal_template&&u(A,C,"font-size:20px;line-height:28px;color:white;",`paying with the
rewards app
`),u(S,L,"display:flex;flex-direction:row;justify-content:right;align-items:center;"),u(q,S,"line-height:16px;color:white;border-radius:50%;background-color:transparent;text-align:center;border:0px;font-weight:400;font-size:20px;cursor:pointer;margin:12px;padding:0px;background-image:url("+O+"close-ic.svg);background-size:80%;background-position:center;background-repeat:no-repeat;");var ie="offer_campaign"===W.design.signUpModal.modal_template||"offer_campaign_v2"===W.design.signUpModal.modal_template||"non_offer"===W.design.signUpModal.modal_template?";height:230px;object-fit:cover;":"";ae?.header_image_url?u(D,C,"width:100%;z-index:2147483640;border-top-left-radius:"+de+";border-top-right-radius:"+de+";font-size:"+ae.body_text_size+"px;display:block;line-height:1.2"+ie):u(I,C,"width:100%;height:230px;z-index:2147483640;border-top-left-radius:"+de+";border-top-right-radius:"+de+";font-size:"+ae.body_text_size+"px;background-color:"+ae.tout_background_color+";display:block;line-height:1.2"),u(V,R,"height:3%;width:100%;"+(window.innerWidth>1200?"":"right:7%;")),u(Y,V,"display:flex;flex-direction:row;justify-content:right;align-items:center;position:relative;bottom:12px;left:7%;"),u(ee,Y,"line-height:16px;color:white;border-radius:50%;background-color:rgb(0,0,0,.8);font-size:20px;text-align:center;border:0px;font-weight:100;cursor:pointer;margin:12px;position:relative;right:3%;padding:0px;background-image:url("+O+"close-ic.svg);background-size:80%;background-position:center;background-repeat:no-repeat;"),u(U,k,"padding:16px;overflow:auto;position:relative;border-bottom-left-radius:"+de+";border-bottom-right-radius:"+de),re.body_text.replace("","").replace("
","").replace(" ","").trim().length>0&&u(j,U,"padding-bottom:16px;",re.body_text),j.innerHTML=j.innerHTML.replace(/\n/g," "),u(N,U,"margin-bottom: 0px;"),u(R,w,"display:none;padding:16px;border-radius:"+de),u(Z,R,"font-size:32px;text-align:center;line-height:36px;font-weight:600;padding-bottom:20px;color:"+t(ae.background_color),""),u(K,R,"",se.success_body),u(G,R,"font-size:"+ae.body_text_size+"px;color:"+ae.body_text_color,""),u(ne,R,"margin-top:16px; margin-bottom: 0px; overflow:auto;"),p&&v(J,h,e,x),"signup_to_fab"!==e.design.floatingAccessButton.fab_behaviour&&"desktop_fab_none"!==e.design.floatingAccessButton.desktop_display_location&&"mobile_fab_mobile_none"!==e.design.floatingAccessButton.mobile_display_location&&s.classList.add("fab-body"),document.getElementById("frame").contentWindow.document.addEventListener("keydown",(n=>{y(n,window.__success_state?R:k),"Escape"===n.key&&"no_display"!==e.design.signUpModal.signup_modal_display_position&&"desktop_fab_none"===e.design.floatingAccessButton.desktop_display_location&&"mobile_fab_mobile_none"===e.design.floatingAccessButton.mobile_display_location?i(e,h,J):"Escape"===n.key&&"tiers"!==le.fab_behaviour&&f(x,b,oe,e,J)})),q.addEventListener("click",(function(n){n.preventDefault(),$([{subscriber_id:null,device_id:pe,event_name:"close_modal",time:Date.now(),event_properties:{brand_id:e.behavior.brand_id},custom_fields:{brand_properties:[],project_properties:[]}}]),"no_display"!==e.design.signUpModal.signup_modal_display_position&&"desktop_fab_none"===e.design.floatingAccessButton.desktop_display_location&&"mobile_fab_mobile_none"===e.design.floatingAccessButton.mobile_display_location?i(e,h,J):"tiers"!==le.fab_behaviour&&f(x,b,oe,e,J)})),oe.addEventListener("click",(()=>{$([{subscriber_id:null,device_id:pe,event_name:"click_fab",time:Date.now(),event_properties:{brand_id:e.behavior.brand_id,desktop_display_location:e.design.floatingAccessButton.desktop_display_location,mobile_display_location:e.design.floatingAccessButton.mobile_display_location},custom_fields:{brand_properties:[],project_properties:[]}}]),_(x,b,oe,e,J),document.getElementById("frame").contentWindow.document.querySelector("#iframe-flex").focus()})),ee.addEventListener("click",(function(n){n.preventDefault,"no_display"!==e.design.signUpModal.signup_modal_display_position&&"desktop_fab_none"===e.design.floatingAccessButton.desktop_display_location&&"mobile_fab_mobile_none"===e.design.floatingAccessButton.mobile_display_location?i(e,h,J):"tiers"!==le.fab_behaviour&&(f(x,b,oe,e,J),i(e,h,J))}));var pe="";M((function(e){pe=e})),e.experiment.flag_key&&e.experiment.variant&&$([{subscriber_id:null,device_id:pe,event_name:"$exposure",time:Date.now(),event_properties:{flag_key:e.experiment.flag_key,variant:e.experiment.variant},custom_fields:{property_groups:[],user_properties:[],event_properties:[]}}]);var me=document.getElementById("frame").contentWindow.document.getElementById("email");me.addEventListener("blur",(()=>{$([{subscriber_id:null,device_id:pe,event_name:"enter_modal_email",time:Date.now(),event_properties:{email:me.value,brand_id:W.behavior.brand_id},custom_fields:{property_groups:[],user_properties:[],event_properties:[]}}])})),N.addEventListener("submit",(function(n){n.preventDefault(),$([{subscriber_id:null,device_id:pe,event_name:"submit_modal",time:Date.now(),event_properties:{email:me.value,brand_id:W.behavior.brand_id},custom_fields:{property_groups:[],user_properties:[],event_properties:[]}}]),l(0,b.contentWindow.document),document.getElementById("frame").contentWindow.document.getElementById("signup-button-label").disabled=!0,te.style.opacity="0.2",setTimeout((()=>{k.style.display="none",R.style.display="block",window.__success_state=!0,J.focus()}),1e3),Object.values(e.design.successModal.inputs).every((e=>!1===e))&&(!0===e.behavior.show_after_submit&&o.createCookie(F+window.__inkind_num,!0,365),o.createCookie(F+window.__inkind_num,!0,e.behavior.delay_days)),this.style.color="red"})),s.addEventListener("click",(function(n){!0===window.__success_state&&"BODY"===n.target.tagName&&i(e,h,J)})),ne.addEventListener("submit",(function(n){n.preventDefault(),l(1,b.contentWindow.document),h.style.opacity="0%",window.__modal_open=!1,setTimeout((function(){h.style.diplay="none"}),300),!0===e.behavior.show_after_submit&&o.createCookie(F+window.__inkind_num,!0,365),o.createCookie(F+window.__inkind_num,!0,e.behavior.delay_days)}));var ge=1e3*e.behavior.loading_delay;setTimeout((function(){h.style.opacity="100%",window.__modal_open=!0,J.ariaHidden="iframe-unentered"===b.className,J.tabIndex=1,h.style.transition="opacity .3s",frame.style.pointerEvents="auto",document.getElementById("frame").contentWindow.document.querySelector("#iframe-flex").focus()}),ge)}),200),window.ikmpl2||(window.ikmpl2=!0)}}function z(){S(),setInterval(A,6e4),setTimeout(B,800)}function B(){document.getElementById("frame")&&M((function(e){$([{subscriber_id:null,device_id:e,event_name:"view_modal",time:Date.now(),event_properties:{brand_id:R},custom_fields:{property_groups:[],user_properties:[],event_properties:[]}}])}))}function A(){const e=parseInt(k(N),10),n=(new Date).getTime();if(e&&n-e>q){const e=L();o.createCookie(j,e,D)}}function T(){const e=(new Date).getTime();o.createCookie(N,e,D)}function S(){["mousemove","click","keydown"].forEach((e=>{document.addEventListener(e,T)}))}const q=18e5,D=365,I=365,U="device_id",j="session_id",N="last_activity";if(e.__inkind_modal_loaded)return;e.__inkind_modal_loaded=!0;var O,P,W,F="a0pc93l9";window.ikmpl1=!0,window.__modal_open=!1;var H,R,Z={},K=window.location.href.replace(window.location.hash,"");-1!==K.indexOf("localhost")||-1!==window.location.hash.indexOf("inkind-local")?(O="http://app.localhost:3000/",P="equityeats-test"):-1!==K.indexOf("inkind-staging")||-1!==window.location.hash.indexOf("inkind-staging")?(O="https://app.inkind-staging.com/",P="equityeats-test"):(O="https://app.inkind.com/",P="equityeats"),o.createCookie=function(e,n,t){if(!("number"==typeof t&&t<=0)){var o=new Date,i=o.getDate()+t;o.setDate(i);var a="session"===t?"":"; expires="+o.toGMTString();document.cookie=e+"="+n+a+"; path=/"}},o.readCookie=function(e){for(var n=e+"=",t=document.cookie.split(";"),o=0;o{let n=`\n .iframe-unentered {\n transition: transform 0.2s; \n position: fixed;\n border: none; z-index: 2147483640; padding: 0; width: 80px; height: 80px; border-radius: ${"tiers"!==e.fab_behaviour?"18px":"50%"}; box-shadow: 0 5px 10px rgba(0,0,0,.5);\n }\n @media only screen and (min-width: 1201px) {\n .iframe-unentered {\n ${g("desktop",e)} \n }\n }\n @media only screen and (max-width: 1200px) {\n .iframe-unentered {\n ${g("mobile",e)}\n }\n }\n @media (hover: hover) {\n .iframe-unentered:hover{\n transform: scale3d(1.05, 1.05, 1.05);\n }\n } \n @media only screen and (max-width: 799px) {\n .iframe-unentered {\n width: 80px;\n height: 80px;\n }\n }\n .iframe-entered {\n top:-1px; z-index:2147483645; background-color:transparent; border:none; position:fixed;height:100vh;width:100%;display: flex;\n }\n `,t=document.createElement("style");t.innerText=n,document.head.appendChild(t)},ee=async e=>{let n=m("iframe");n.id="frame",n.title="A special welcome gift",setTimeout((()=>{let n=m("title");n.textContent=`an opportunity to claim a special welcome gift for when you visit ${e?.behavior?.brand_name} and pay using the inKind app`,document.getElementById("frame").contentDocument.head.appendChild(n)}),500);let t=m("div"),o=m("img");o.alt="Fab image";let i=e.design.floatingAccessButton,a=e.design.signUpModal,r=e.behavior.slug,l=e.design.colorAndStyle;t.id="inkindmodal",o.src=i.fab_cta_image_url,bannerImage="https://res-2.cloudinary.com/"+P+"/image/upload/"+l.brand_image_url,M((function(n){e.experiment.flag_key&&e.experiment.variant&&$([{subscriber_id:null,device_id:n,event_name:"$exposure",time:Date.now(),event_properties:{flag_key:e.experiment.flag_key,variant:e.experiment.variant},custom_fields:{property_groups:[],user_properties:[],event_properties:[]}}]);let t={cas:l,fab:i,fabImg:o,mode:a.tiers_banner_mode,bannerImage:bannerImage};s(O+`api/public/offers/${r}`,"GET",null,t)}))},ne=(e,n)=>{const t=e,o=n.fabImg,i=n.fab,a=n.bannerImage,r=n.cas;Q(i);let s=document.getElementsByTagName("body")[0],l=m("iframe");l.id="frame",l.title="A special welcome gift",l.className="iframe-unentered";let d=m("div"),c=m("div"),p=m("div"),g=m("div"),f=m("button"),_=m("button");u(l,s),setTimeout((()=>{let e=m("title");e.textContent=`an opportunity to claim a special welcome gift for when you visit ${t.account} and pay using the inKind app`;let n=document.getElementById("frame").contentWindow.document.body;n?.focus(),n.style.margin="0px";let i=document.getElementById("frame").contentDocument;n.style.padding="0px",n.style.minHeight="100px";var b=new FontFace("Rethink-Sans-Medium","url("+O+"/assets/maps/RethinkSans-Medium.ttf)");let h=i.createElement("link");h.setAttribute("rel","stylesheet"),h.setAttribute("type","text/css"),h.setAttribute("href",b),i.head.appendChild(h),i.head.appendChild(e);let y="\n body {\n font:18px 'Rethink-San-Regular', sans-serif;\n }\n .show-button-entered{\n position: fixed;\n display: none;\n cursor: pointer; border: none; background-color:transparent; border-radius: 50%;\n }\n .show-button-unentered{\n cursor: pointer; position: fixed; border: none; background-color:transparent; border-radius: 50%; padding: 0px; transition: transform 0.2s;\n }\n .show-button-unentered > img{\n height:120px; width:120px; background-size:cover; position:relative;\n }\n\n\n .svg-text{\n fill:white;\n\n }\n .modal-content{\n width: 100%;\n display: flex;\n justify-content: center;\n flex-direction: column;\n\n margin: 0 auto;\n }\n .modal-logo{\n margin: 0 auto;\n width: 200px;\n padding: 24px 24px 0px;\n }\n hr{\n width: 99%;\n border-top: 1px solid whitesmoke;\n\n }\n\n\n .panel-options-wrapper {\n display: flex;\n flex-direction: column;\n padding: 22px 20px;\n background-color: #f3f4fb;\n border-bottom-left-radius: 12px;\n border-bottom-right-radius: 12px;\n }\n .panel-options-wrapper:not(:last-child){\n\n }\n .account-choice-wrapper{\n position: relative;\n transition: transform 0.2s;\n }\n @media (hover: hover) {\n .account-choice-wrapper:hover{\n transform: translate(0, -1px);\n }\n }\n .tiers-copy-text{\n padding: 16px 0;\n width: 200px;\n text-align: center;\n margin: 0 auto;\n }\n .ribbon {\n text-align: center;\n height: 22px;\n position: absolute;\n z-index: 1;\n top: -10px;\n left: 0;\n right: 0;\n margin-left: auto;\n margin-right: auto;\n margin-bottom: auto;\n text-decoration: none;\n display: flex;\n align-items: center;\n justify-content: center;\n }\n .ribbon-text {\n letter-spacing: 2px;\n font:13px 'Rethink-San-Regular', sans-serif;\n font-weight: black;\n width: 100%;\n height: 100%;\n display: flex;\n align-items: center;\n justify-content: center;\n line-height: 1;\n z-index: 40;\n position: absolute;\n left: 0;\n right: 0;\n color:white;\n top: -33.5px;\n margin-left: auto;\n margin-right: auto;\n margin-bottom: auto;\n }\n .tier-button{\n position: relative;\n height: 70px;\n width: 100%;\n margin-bottom: 16px;\n border-radius: 12px;\n font:20px 'Rethink-San-Regular', sans-serif;\n font-weight: 400;\n background-color: black;\n border: none;\n color: white;\n cursor: pointer;\n }\n .button-chevron {\n position: absolute;\n right: 18px;\n top: 50%;\n transform: translateY(-50%);\n display: flex;\n }\n .chevron {\n width: 20px;\n height: 20px;\n }\n .tier-link{\n cursor: pointer;\n\n }\n strong{\n font-weight: 600\n }\n\n .tiers-learn-more-button{\n text-decoration: none;\n color: #8eaed0;\n background-color:white;\n border: none;\n border-top: 2px solid whitesmoke;\n font:18px 'Rethink-San-Regular', sans-serif;\n font-weight: 400;\n height: 60px;\n display:flex;\n align-items:center;\n justify-content: center;\n cursor: pointer;\n width: 100%;\n }\n @media (hover: hover) {\n .tiers-learn-more-button:hover{\n color: #7ea2c9;\n }\n }\n ",x=i.createElement("style");x.innerText=y,i.head.appendChild(x);const v=()=>{p.animate(V,Y),setTimeout((()=>{s.style.overflow="initial",d.style.display="none",window.__modal_open=!1,l.className="iframe-unentered",f.className="show-button-unentered"}),170)},w=()=>{s.style.overflow="hidden",l.className="iframe-entered",d.style.display="block",window.__modal_open=!0,p.animate(J,Y),f.className="show-button-entered"};document.getElementById("frame").contentWindow.document.addEventListener("keydown",(e=>{"Escape"===e.key&&(v(),document.removeEventListener("keydown",e))})),_.addEventListener("click",(()=>{v()})),f.addEventListener("click",(()=>{w()})),u(f,n,""),u(o,f,""),f.className="show-button-unentered",u(d,n,"overflow-y: auto; position:fixed;height:100%;width:100%;display:none; top: 0px; left: 0px; "),u(c,d,"width: 100%; height: 100%; padding: 0px; display: flex;"),u(p,c,`z-index:2147483641;${window.innerWidth>1200?"width:432px;":"width:350px;"} background-color: white; margin: auto; border-radius: 12px; box-shadow: 0 0px 2px rgba(255,255,255,0.85), 0 5px 15px rgba(0,0,0,.65); display:flex; flex-direction:column; position:relative;`),u(_,p,"background-color:white; border:none; color:white; cursor:pointer; position:absolute; right:20px; top: 20px; padding: 0; border-radius: 50%",'\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n '),
u(g,p,"width: 100%;",`\n \n
\n
Start a House Account and get rewarded! \n
\n \n \n Learn More\n \n \n
\n\n
\n\n\n\n \n\n `),w(),setTimeout((()=>{document.getElementById("frame").contentWindow.document.querySelector("#iframe-flex").focus()}),170)}),200)},te=`?domain=${new URL(K).hostname.replace(/^www./,"")}`,oe=window.location.hash.match(/modal-test-(\d+)$/);let ie=`api/v4/capture_modals${te}`;if(oe){ie+=`&modal_test_id=${oe[1]}`}var ae=window.location.href.includes("#viainkind");ae&&o.createCookie(F+0,!0,"session"),n()&&!ae&&(z(),s(`${O}${ie}`,"GET"))}(window);